﻿using UnityEngine;
using System.Collections;

public class JagementTip : MonoBehaviour {
	public SpriteRenderer tip;
	public Sprite good;
	public Sprite perfect;
	public Sprite miss;
	private Animator animator;

	// Use this for initialization
	void Start () {
		animator = GetComponent<Animator> ();
	}
	
	// Update is called once per frame
	void Update () {

	}

	public void ShowUpResult(JageResult rst)
	{
		if(rst == JageResult.Perfect)
			tip.sprite = perfect;
		else if(rst == JageResult.Good)
			tip.sprite = good;
		else if(rst == JageResult.Fail)
			tip.sprite = miss;

		animator.SetTrigger ("tShow");
	}
}
